<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
  <meta charset="utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <title>校园管理系统布局 - Layui</title>
  <link rel="stylesheet" th:href="@{/layui/css/layui.css}">
  <link rel="stylesheet" th:href="@{/layer/mobile/need/layer.css}">
  <style>
    .layui-table-view .layui-form-checkbox[lay-skin=primary] i {
      margin-top:8px;
    }
  </style>
</head>
<body>

<div class="layui-layout layui-layout-admin">
  <div class="layui-header">
    <div class="layui-logo layui-hide-xs layui-bg-black">校园应用系统</div>
    <!-- 头部区域（可配合layui 已有的水平导航） -->
    <ul class="layui-nav layui-layout-left">
      <!-- 移动端显示 -->
      <li class="layui-nav-item layui-show-xs-inline-block layui-hide-sm" lay-header-event="menuLeft">
        <i class="layui-icon layui-icon-spread-left"></i>
      </li>

      <li class="layui-nav-item layui-hide-xs"><a href="">nav 1</a></li>
      <li class="layui-nav-item layui-hide-xs"><a href="">nav 2</a></li>
      <li class="layui-nav-item layui-hide-xs"><a href="">nav 3</a></li>
      <li class="layui-nav-item">
        <a href="javascript:;">nav groups</a>
        <dl class="layui-nav-child">
          <dd><a href="">menu 11</a></dd>
          <dd><a href="">menu 22</a></dd>
          <dd><a href="">menu 33</a></dd>
        </dl>
      </li>
    </ul>
    <ul class="layui-nav layui-layout-right">
      <li class="layui-nav-item"><a href="javascript:void(0);">今天是<span id="day"></span>&nbsp;&nbsp;&nbsp;
        <span id="time"></span>
      </a></li>
      <li class="layui-nav-item layui-hide layui-show-md-inline-block">
        <a href="javascript:;">
          <img src="//tva1.sinaimg.cn/crop.0.0.118.118.180/5db11ff4gw1e77d3nqrv8j203b03cweg.jpg" class="layui-nav-img">

        </a>
        <dl class="layui-nav-child">
          <dd><a href="">个人资料</a></dd>
          <dd><a href="">设置</a></dd>
          <dd><a href="">退出系统</a></dd>
        </dl>
      </li>
      <li class="layui-nav-item" lay-header-event="menuRight" lay-unselect>
        <a href="javascript:;">
          <i class="layui-icon layui-icon-more-vertical"></i>
        </a>
      </li>
    </ul>
  </div>

  <div class="layui-side layui-bg-black">
    <div class="layui-side-scroll">
      <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
      <ul class="layui-nav layui-nav-tree layui-bg-cyan layui-inline" lay-filter="demo">
        <li class="layui-nav-item layui-nav-itemed">
          <a class="" href="javascript:;">学生管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/stu/sel}">学生基本信息管理</a></dd>

          </dl>
        </li>
        <li class="layui-nav-item">
          <a href="javascript:;">教室管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/room/sel}">教室基本信息管理</a></dd>

          </dl>
        </li>

        <li class="layui-nav-item">
          <a href="javascript:;">班级管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/gra/sel}">班级基本信息管理</a></dd>

          </dl>
        </li>
        <li class="layui-nav-item">
          <a href="javascript:;">宿舍管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/dorm/sel}">宿舍基本信息管理</a></dd>
          </dl>
        </li>
        <li class="layui-nav-item">
          <a href="javascript:;">课程管理</a>
          <dl class="layui-nav-child">
            <dd><a th:href="@{/curr/sel}">课程基本信息管理</a></dd>
          </dl>
        </li>
      </ul>
    </div>
  </div>

  <div class="layui-body">
    <!-- 内容主体区域 -->
    <fieldset class="layui-elem-field layui-field-title" style="margin-top: 20px;">
      <legend>宿舍基本信息管理</legend>
    </fieldset>
    <div class="demoTable">
      <form class="layui-form">
        <div class="layui-form-item">
          <label class="layui-form-label">宿舍区域：</label>
          <div class="layui-input-inline">
            <select id="area" lay-filter="area" lay-search>
<!--              <option value=" ">&#45;&#45;请选择区域&#45;&#45;</option>-->
            </select>
          </div>

          <div class="layui-input-inline">
            <select id="buildingNo" lay-filter="buildingNo" disabled>
<!--              <option value=" ">&#45;&#45;请选择楼号&#45;&#45;</option>-->
            </select>
          </div>

          <div class="layui-input-inline">
            <select id="buildingFloor" lay-filter="buildingFloor" disabled>
<!--              <option value=" ">&#45;&#45;请选择楼层&#45;&#45;</option>-->
            </select>
          </div>
        </div>
      </form>



      <div class="layui-form-item">
        <label class="layui-form-label">宿舍名称：</label>
        <div class="layui-input-inline" style="width: 120px">
          <input type="text" name="dormitoryName" id="dormitoryName" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
        </div>
        <label class="layui-form-label">床位数量：</label>
        <div class="layui-input-inline " style="width: 120px">
          <input type="text" name="bedNumber" id="bedNumber" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">
        </div>
        <label class="layui-form-label">使用情况：</label>
        <div class="layui-input-inline" style="width: 140px">
<!--          <input type="text" name="useStatus" id="useStatus" lay-verify="required" placeholder="请输入" autocomplete="off" class="layui-input">-->
          <form class="layui-form">
              <select id="useStatus" lay-filter="useStatus">
                <option value="">--请选择状态--</option>
                <option value="0">正常</option>
                <option value="1">空闲</option>
                <option value="2">停用</option>
                <option value="3">保留</option>
              </select>
          </form>
        </div>

        <button class="layui-btn layui-btn-warm layui-btn-radius layui-btn-lg" data-type="reload">查询</button>
        <!--  下拉框输入文字-->
        <select  onkeydown="catch_keydown(this);" onkeypress="catch_press(this);" class="layui-input-inline layui-form-label " >
          <option>aaaaa</option>
          <option>bbbbb</option>
        </select>

      </div>

      <table class="layui-hide" id="demo" lay-filter="test"></table>

      <script type="text/html" id="barDemo">
        <a class="layui-btn layui-btn-xs" lay-event="detail">查看</a>
        <a class="layui-btn layui-btn-xs" lay-event="more">更多 <i class="layui-icon layui-icon-down"></i></a>

      </script>

    </div>

    <div class="layui-footer">
      <!-- 底部固定区域 -->
      底部固定区域
    </div>
  </div>

<!--  查看界面-->
  <div id="findDorm" style="display:none">


    <div class="layui-form-item">
      <label class="layui-form-label">宿舍id：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selDormitoryId"  readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>


    <div class="layui-form-item">
      <label class="layui-form-label">宿舍名称：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selDormitoryName" readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">床位数量：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selBedNumber" readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 300px" >
      </div>
    </div>

    <div>
      <label class="layui-form-label">主管id：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selDormSupervisorId" readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div>
      <label class="layui-form-label">宿舍主管：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selDormSupervisor" readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div><br/>

    <div class="layui-form-item">
      <label class="layui-form-label">使用状态：</label>
      <select name="selUseStatus" id="selUseStatus" readonly lay-verify="required" lay-search="" class="layui-select" >
        <option value='0'>正常</option>
        <option value='1'>空闲</option>
        <option value='2'>停用</option>
        <option value='3'>保留</option>
      </select>
    </div>

    <div>
      <label class="layui-form-label">备注：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="selRemark" readonly lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div><br/>

    <button class="layui-btn" id="addStu" style="margin-left: 110px;">添加学生</button>
    <button class="layui-btn" id="selStu" style="margin-left: 110px;">查看学生</button>
  </div>


  <!--   修改界面-->
  <div id="updatePage" style="display:none">
    <div class="layui-form-item">900px9
      <label class="layui-form-label">区域：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updArea" placeholder="x区域" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">楼号：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updBuildingNo" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">楼层：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updBuildingFloor" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">宿舍id：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updDormitoryId" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>


    <div class="layui-form-item">
      <label class="layui-form-label">宿舍名称：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updDormitoryName" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">床位数量：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updBedNumber" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 300px" >
      </div>
    </div>

    <div>
      <label class="layui-form-label">主管id：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updDormSupervisorId" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div><br/>

    <div>
      <label class="layui-form-label">宿舍主管：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updDormSupervisor" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">使用状态：</label>
      <select name="updUseStatus" id="updUseStatus" lay-verify="required" lay-search="" class="layui-select" >
        <option value='0'>正常</option>
        <option value='1'>空闲</option>
        <option value='2'>停用</option>
        <option value='3'>保留</option>
      </select>
    </div>

    <div>
      <label class="layui-form-label">备注：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="updRemark" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div><br/>

    <button class="layui-btn" id="updateDorm" style="margin-left: 110px;">确认修改</button>
  </div>


<!--  添加界面-->
  <div id="insertPage" style="display: none">
    <div class="layui-form-item">
      <label class="layui-form-label">区域：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addArea" placeholder="x区域" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">楼号：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addBuildingNo" placeholder="x号楼" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">楼层：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addBuildingFloor" placeholder="x层" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">宿舍id：</label>
      <input type="text" name="title" id="addDormitoryId" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
    </div>



    <div class="layui-form-item">
      <label class="layui-form-label">宿舍名称：</label>
      <input type="text" name="title" id="addDormitoryName" placeholder="xxxx" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 200px" >
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">床位数量：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addBedNumber" placeholder="number" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 300px" >
      </div>
    </div>

    <div class="layui-inline">
      <label class="layui-form-label">宿舍主管id：</label>
      <div class="layui-input-inline">
        <input type="text" name="people" id="addDormSupervisorId" lay-verify="date" placeholder="" autocomplete="off" class="layui-input" style="margin-bottom: 15px;width: 300px" >
      </div>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">宿舍主管：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addDormSupervisor" placeholder="xxx" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 300px" >
      </div>
    </div>

    <div>
      <label class="layui-form-label">使用状态：</label>

      <select name="addUseStatus" id="addUseStatus" lay-verify="required" lay-search="" class="layui-select" >
        <option value='0'>正常</option>
        <option value='1'>空闲</option>
        <option value='2'>停用</option>
        <option value='3'>保留</option>
      </select>
    </div>

    <div class="layui-form-item">
      <label class="layui-form-label">详细信息：</label>
      <div class="layui-input-block">
        <input type="text" name="title" id="addRemark" lay-verify="title" autocomplete="off" value="" class="layui-input" style="margin-top: 15px;width: 300px" >
      </div>
    </div>

    <button class="layui-btn" id="insertDorm" style="margin-left: 110px;">确认添加</button>
  </div>


  <script type="text/javascript" th:src="@{/layui/layui.js}"></script>
  <script type="text/javascript" th:src="@{/js/dateTime.js}"></script>
  <!--    <script type="text/javascript" src="${pageContext.request.contextPath}/static/js/jquery-1.4.4.min.js"></script>-->
  <script type="text/javascript" th:src="@{/js/jquery-1.8.3.min.js}"></script>
  <script type="text/javascript" th:src="@{/layer/layer.js}"></script>
  <script type="text/javascript" th:src="@{/js/phoenix/dormitoryInfo.js}"></script>
  <script type="text/javascript" th:src="@{/js/laydate.js}"></script>
  <script type="text/javascript">
    //显示实时时间
    $(function () {
      showDay();
      setInterval('showTime()');
    })
  </script>

</body>
</html>